Skip to main content

Save User ExtraField Option

POST : http://<base_url>/digipay/v3/user/user_extra_field_options

This API is utilized to store new user extrafield options with in the system.

BODY PARAMS:-

ParameterTypeDescriptionValue
titleStringThis represents the title or name associated with the data. It could be the title of an article, a product, or any other type of content.hello
keyStringThe key serves as an identifier for the data. It might be used for indexing, referencing, or uniquely identifying the data in a system.1213
imageStringThis field holds the URL or file path of an image associated with the data. It could be used to display an image alongside the data.image_url.jpg
dependStringRepresents a dependency value that the data might rely on. This could be used to establish relationships or conditional behavior.dependency_value
extra_field_keyStringAn additional key that might be used to represent supplementary information or metadata related to the data.extra_key
parent_keyStringA key that links the data to a parent element. This might be useful when the data is part of a hierarchical structure.parent_key_value"
parent_valueStringThe value associated with the parent element. It complements the parent_key and provides the actual reference or connection to the parent."400 Bad Request: The request parameters or payload are invalid or missing.parent_value

HEADERS:-

ParameterTypeDescriptionValue
AuthorizationStringIt is a combination of type and token to authenticate user for the given tokenToken duik7309njdlkhdauhknksadhjkas986876sd873j
CompanyIDStringCompany_id is a unique primary id, that is represent company detail76bc712200ca444fa334f9e55e5fd7a8

Request Body:-

Request Example
curl --request POST \
--url http://192.168.1.102:8014/digipay/v3/user/user_extra_field_options \
--header 'Authorization: Token eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzdWIiOiI2NWY0ZDI1MDliZmU0NTBmYTg4MTVhNTU5Njk3YmM0NyIsInJvbGVzIjpbIlJPTEVfQURNSU4iXSwiZXhwIjoxNjkzNTIxOTU1fQ.9oWwUzlFzmYB1ZOhaVamxKJH6DsMO8tFue2kbg2YyoI' \
--header 'CompanyID: 76bc712200ca444fa334f9e55e5fd7a8' \
--header 'accept: application/json' \
--header 'content-type: application/json' \
--data '
{
"title": "hello",
"key": "123",
"image": "image_url.jpg",
"depend": "dependency_value",
"extra_field_key": "extra_key",
"parent_key": "parent_key_value\"",
"parent_value": "parent_value"
}
'

Response:-

Response 200(OK)

{
"success": 1,
"error": [],
"data": {
"message": "User extra field option data saved successfully.",
"user_extra_field_option_id": "61457e993a294323944a1c2e7c812338"
}
}
Response 400(BAD REQUEST)
{
"success": 0,
"error"": [1],
"data": {
"message": "BAD_REQUEST",
}
}

RESPONSES :-

Status CodeDescription
200OK
400BAD REQUEST
404NOT FOUND
500INTERNAL SERVER ERROR